Решение на Python:
def to_27(n):
ost = []
while n:
ost.append(n % 27)
n //= 27
return ost[::-1]
print(len([el for el in to_27(2 * 2187**567 + 729**566 - 2 * 243**565 + 81**564 - 2 * 27**563 -6561) if el > 9 and el % 2 == 0])) # 940Ответ: 940
Автор - rubygem17
None